-
-
Notifications
You must be signed in to change notification settings - Fork 389
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs: mention id
field in 1-abstract-dto.rst
#3803
Conversation
Quality Gate passedIssues Measures |
I'm not really sure "special" is the right wording here, since it's simply an inherited attribute. It only happens to be the only one that's inherited from the base class, but there's nothing special about the |
@provinzkraut can we say that "id is readonly because it is a primary key"? |
I think it should say something like "we mark |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3803 +/- ##
=======================================
Coverage 98.36% 98.36%
=======================================
Files 346 347 +1
Lines 15690 15722 +32
Branches 1737 1737
=======================================
+ Hits 15433 15465 +32
Misses 122 122
Partials 135 135 ☔ View full report in Codecov by Sentry. |
I'm going to go ahead and merge with the provided updates. We can open a followup PR to dial in the verbiage if needed. Thanks @sobolevn |
Quality Gate passedIssues Measures |
Documentation preview will be available shortly at https://litestar-org.github.io/litestar-docs-preview/3803 |
It caught my attention that it was never explained: why do we have an extra
id
field in the response. Since this part is dedicated to explaining how request / response fields are marked, I think that it is important to mention thatid
is special:I had to grep what
.my_lib
is and howclass _Base(CommonTableAttributes, UUIDPrimaryKey, DeclarativeBase):
is constructed. Only findingUUIDPrimaryKey
and itsid: Mapped[UUID] = mapped_column(default=uuid4, primary_key=True)
has anwsered my question :)